#include<stdio.h>
int fac(int i)
{
	int a=1;
	int b=1;
	int c=1;
	while(i>2)
	{
	c=a+b;
	a=b;
	b=c;
	i--;
	
	}

	return c;
	
}

//1 1 2 3 5 8 13 21 34 55
//2 3 5
//1 2 3
//2 3 5
int main()
{
	int i=0;
	int a=0;
	scanf("%d",&i);
	a=fac(i);
	printf("%d",a);
	
	
 } 
